/**
 */
package autoSAR.util;

import autoSAR.*;

import org.eclipse.emf.ecore.EObject;
import org.eclipse.emf.ecore.EPackage;

import org.eclipse.emf.ecore.util.Switch;

/**
 * <!-- begin-user-doc -->
 * The <b>Switch</b> for the model's inheritance hierarchy.
 * It supports the call {@link #doSwitch(EObject) doSwitch(object)}
 * to invoke the <code>caseXXX</code> method for each class of the model,
 * starting with the actual class of the object
 * and proceeding up the inheritance hierarchy
 * until a non-null result is returned,
 * which is the result of the switch.
 * <!-- end-user-doc -->
 * @see autoSAR.AutoSARPackage
 * @generated
 */
public class AutoSARSwitch<T> extends Switch<T> {
	/**
	 * The cached model package
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	protected static AutoSARPackage modelPackage;

	/**
	 * Creates an instance of the switch.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public AutoSARSwitch() {
		if (modelPackage == null) {
			modelPackage = AutoSARPackage.eINSTANCE;
		}
	}

	/**
	 * Checks whether this is a switch for the given package.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @param ePackage the package in question.
	 * @return whether this is a switch for the given package.
	 * @generated
	 */
	@Override
	protected boolean isSwitchFor(EPackage ePackage) {
		return ePackage == modelPackage;
	}

	/**
	 * Calls <code>caseXXX</code> for each class of the model until one returns a non null result; it yields that result.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @return the first non-null result returned by a <code>caseXXX</code> call.
	 * @generated
	 */
	@Override
	protected T doSwitch(int classifierID, EObject theEObject) {
		switch (classifierID) {
		case AutoSARPackage.COMPOSITION_SWC: {
			CompositionSWC compositionSWC = (CompositionSWC) theEObject;
			T result = caseCompositionSWC(compositionSWC);
			if (result == null)
				result = defaultCase(theEObject);
			return result;
		}
		case AutoSARPackage.SWC: {
			SWC swc = (SWC) theEObject;
			T result = caseSWC(swc);
			if (result == null)
				result = defaultCase(theEObject);
			return result;
		}
		case AutoSARPackage.APPLICATION_SWC: {
			ApplicationSWC applicationSWC = (ApplicationSWC) theEObject;
			T result = caseApplicationSWC(applicationSWC);
			if (result == null)
				result = caseSWC(applicationSWC);
			if (result == null)
				result = defaultCase(theEObject);
			return result;
		}
		case AutoSARPackage.COMPLEX_DEVICE_DRIVER_SWC: {
			ComplexDeviceDriverSWC complexDeviceDriverSWC = (ComplexDeviceDriverSWC) theEObject;
			T result = caseComplexDeviceDriverSWC(complexDeviceDriverSWC);
			if (result == null)
				result = caseSWC(complexDeviceDriverSWC);
			if (result == null)
				result = defaultCase(theEObject);
			return result;
		}
		case AutoSARPackage.IB: {
			IB ib = (IB) theEObject;
			T result = caseIB(ib);
			if (result == null)
				result = defaultCase(theEObject);
			return result;
		}
		case AutoSARPackage.PORTS: {
			Ports ports = (Ports) theEObject;
			T result = casePorts(ports);
			if (result == null)
				result = defaultCase(theEObject);
			return result;
		}
		case AutoSARPackage.PPORT_SET: {
			PPortSet pPortSet = (PPortSet) theEObject;
			T result = casePPortSet(pPortSet);
			if (result == null)
				result = defaultCase(theEObject);
			return result;
		}
		case AutoSARPackage.RPORT_SET: {
			RPortSet rPortSet = (RPortSet) theEObject;
			T result = caseRPortSet(rPortSet);
			if (result == null)
				result = defaultCase(theEObject);
			return result;
		}
		case AutoSARPackage.POST_RECIVE_PORT: {
			PostRecivePort postRecivePort = (PostRecivePort) theEObject;
			T result = casePostRecivePort(postRecivePort);
			if (result == null)
				result = casePorts(postRecivePort);
			if (result == null)
				result = defaultCase(theEObject);
			return result;
		}
		case AutoSARPackage.CLIENT_SERVICE_PORT: {
			ClientServicePort clientServicePort = (ClientServicePort) theEObject;
			T result = caseClientServicePort(clientServicePort);
			if (result == null)
				result = casePorts(clientServicePort);
			if (result == null)
				result = defaultCase(theEObject);
			return result;
		}
		case AutoSARPackage.ENTITY: {
			Entity entity = (Entity) theEObject;
			T result = caseEntity(entity);
			if (result == null)
				result = defaultCase(theEObject);
			return result;
		}
		case AutoSARPackage.CLIENT_SERVICE_RPORT: {
			ClientServiceRPort clientServiceRPort = (ClientServiceRPort) theEObject;
			T result = caseClientServiceRPort(clientServiceRPort);
			if (result == null)
				result = caseClientServicePort(clientServiceRPort);
			if (result == null)
				result = casePorts(clientServiceRPort);
			if (result == null)
				result = defaultCase(theEObject);
			return result;
		}
		case AutoSARPackage.CLIENT_SERVICE_PPORT: {
			ClientServicePPort clientServicePPort = (ClientServicePPort) theEObject;
			T result = caseClientServicePPort(clientServicePPort);
			if (result == null)
				result = caseClientServicePort(clientServicePPort);
			if (result == null)
				result = casePorts(clientServicePPort);
			if (result == null)
				result = defaultCase(theEObject);
			return result;
		}
		case AutoSARPackage.POST_RECIVE_RPORT: {
			PostReciveRPort postReciveRPort = (PostReciveRPort) theEObject;
			T result = casePostReciveRPort(postReciveRPort);
			if (result == null)
				result = casePostRecivePort(postReciveRPort);
			if (result == null)
				result = casePorts(postReciveRPort);
			if (result == null)
				result = defaultCase(theEObject);
			return result;
		}
		case AutoSARPackage.POST_RECIVE_PPORT: {
			PostRecivePPort postRecivePPort = (PostRecivePPort) theEObject;
			T result = casePostRecivePPort(postRecivePPort);
			if (result == null)
				result = casePostRecivePort(postRecivePPort);
			if (result == null)
				result = casePorts(postRecivePPort);
			if (result == null)
				result = defaultCase(theEObject);
			return result;
		}
		case AutoSARPackage.VARIABLE: {
			Variable variable = (Variable) theEObject;
			T result = caseVariable(variable);
			if (result == null)
				result = defaultCase(theEObject);
			return result;
		}
		case AutoSARPackage.VARIABLE_SET: {
			VariableSet variableSet = (VariableSet) theEObject;
			T result = caseVariableSet(variableSet);
			if (result == null)
				result = defaultCase(theEObject);
			return result;
		}
		default:
			return defaultCase(theEObject);
		}
	}

	/**
	 * Returns the result of interpreting the object as an instance of '<em>Composition SWC</em>'.
	 * <!-- begin-user-doc -->
	 * This implementation returns null;
	 * returning a non-null result will terminate the switch.
	 * <!-- end-user-doc -->
	 * @param object the target of the switch.
	 * @return the result of interpreting the object as an instance of '<em>Composition SWC</em>'.
	 * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
	 * @generated
	 */
	public T caseCompositionSWC(CompositionSWC object) {
		return null;
	}

	/**
	 * Returns the result of interpreting the object as an instance of '<em>SWC</em>'.
	 * <!-- begin-user-doc -->
	 * This implementation returns null;
	 * returning a non-null result will terminate the switch.
	 * <!-- end-user-doc -->
	 * @param object the target of the switch.
	 * @return the result of interpreting the object as an instance of '<em>SWC</em>'.
	 * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
	 * @generated
	 */
	public T caseSWC(SWC object) {
		return null;
	}

	/**
	 * Returns the result of interpreting the object as an instance of '<em>Application SWC</em>'.
	 * <!-- begin-user-doc -->
	 * This implementation returns null;
	 * returning a non-null result will terminate the switch.
	 * <!-- end-user-doc -->
	 * @param object the target of the switch.
	 * @return the result of interpreting the object as an instance of '<em>Application SWC</em>'.
	 * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
	 * @generated
	 */
	public T caseApplicationSWC(ApplicationSWC object) {
		return null;
	}

	/**
	 * Returns the result of interpreting the object as an instance of '<em>Complex Device Driver SWC</em>'.
	 * <!-- begin-user-doc -->
	 * This implementation returns null;
	 * returning a non-null result will terminate the switch.
	 * <!-- end-user-doc -->
	 * @param object the target of the switch.
	 * @return the result of interpreting the object as an instance of '<em>Complex Device Driver SWC</em>'.
	 * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
	 * @generated
	 */
	public T caseComplexDeviceDriverSWC(ComplexDeviceDriverSWC object) {
		return null;
	}

	/**
	 * Returns the result of interpreting the object as an instance of '<em>IB</em>'.
	 * <!-- begin-user-doc -->
	 * This implementation returns null;
	 * returning a non-null result will terminate the switch.
	 * <!-- end-user-doc -->
	 * @param object the target of the switch.
	 * @return the result of interpreting the object as an instance of '<em>IB</em>'.
	 * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
	 * @generated
	 */
	public T caseIB(IB object) {
		return null;
	}

	/**
	 * Returns the result of interpreting the object as an instance of '<em>Ports</em>'.
	 * <!-- begin-user-doc -->
	 * This implementation returns null;
	 * returning a non-null result will terminate the switch.
	 * <!-- end-user-doc -->
	 * @param object the target of the switch.
	 * @return the result of interpreting the object as an instance of '<em>Ports</em>'.
	 * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
	 * @generated
	 */
	public T casePorts(Ports object) {
		return null;
	}

	/**
	 * Returns the result of interpreting the object as an instance of '<em>PPort Set</em>'.
	 * <!-- begin-user-doc -->
	 * This implementation returns null;
	 * returning a non-null result will terminate the switch.
	 * <!-- end-user-doc -->
	 * @param object the target of the switch.
	 * @return the result of interpreting the object as an instance of '<em>PPort Set</em>'.
	 * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
	 * @generated
	 */
	public T casePPortSet(PPortSet object) {
		return null;
	}

	/**
	 * Returns the result of interpreting the object as an instance of '<em>RPort Set</em>'.
	 * <!-- begin-user-doc -->
	 * This implementation returns null;
	 * returning a non-null result will terminate the switch.
	 * <!-- end-user-doc -->
	 * @param object the target of the switch.
	 * @return the result of interpreting the object as an instance of '<em>RPort Set</em>'.
	 * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
	 * @generated
	 */
	public T caseRPortSet(RPortSet object) {
		return null;
	}

	/**
	 * Returns the result of interpreting the object as an instance of '<em>Post Recive Port</em>'.
	 * <!-- begin-user-doc -->
	 * This implementation returns null;
	 * returning a non-null result will terminate the switch.
	 * <!-- end-user-doc -->
	 * @param object the target of the switch.
	 * @return the result of interpreting the object as an instance of '<em>Post Recive Port</em>'.
	 * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
	 * @generated
	 */
	public T casePostRecivePort(PostRecivePort object) {
		return null;
	}

	/**
	 * Returns the result of interpreting the object as an instance of '<em>Client Service Port</em>'.
	 * <!-- begin-user-doc -->
	 * This implementation returns null;
	 * returning a non-null result will terminate the switch.
	 * <!-- end-user-doc -->
	 * @param object the target of the switch.
	 * @return the result of interpreting the object as an instance of '<em>Client Service Port</em>'.
	 * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
	 * @generated
	 */
	public T caseClientServicePort(ClientServicePort object) {
		return null;
	}

	/**
	 * Returns the result of interpreting the object as an instance of '<em>Entity</em>'.
	 * <!-- begin-user-doc -->
	 * This implementation returns null;
	 * returning a non-null result will terminate the switch.
	 * <!-- end-user-doc -->
	 * @param object the target of the switch.
	 * @return the result of interpreting the object as an instance of '<em>Entity</em>'.
	 * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
	 * @generated
	 */
	public T caseEntity(Entity object) {
		return null;
	}

	/**
	 * Returns the result of interpreting the object as an instance of '<em>Client Service RPort</em>'.
	 * <!-- begin-user-doc -->
	 * This implementation returns null;
	 * returning a non-null result will terminate the switch.
	 * <!-- end-user-doc -->
	 * @param object the target of the switch.
	 * @return the result of interpreting the object as an instance of '<em>Client Service RPort</em>'.
	 * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
	 * @generated
	 */
	public T caseClientServiceRPort(ClientServiceRPort object) {
		return null;
	}

	/**
	 * Returns the result of interpreting the object as an instance of '<em>Client Service PPort</em>'.
	 * <!-- begin-user-doc -->
	 * This implementation returns null;
	 * returning a non-null result will terminate the switch.
	 * <!-- end-user-doc -->
	 * @param object the target of the switch.
	 * @return the result of interpreting the object as an instance of '<em>Client Service PPort</em>'.
	 * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
	 * @generated
	 */
	public T caseClientServicePPort(ClientServicePPort object) {
		return null;
	}

	/**
	 * Returns the result of interpreting the object as an instance of '<em>Post Recive RPort</em>'.
	 * <!-- begin-user-doc -->
	 * This implementation returns null;
	 * returning a non-null result will terminate the switch.
	 * <!-- end-user-doc -->
	 * @param object the target of the switch.
	 * @return the result of interpreting the object as an instance of '<em>Post Recive RPort</em>'.
	 * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
	 * @generated
	 */
	public T casePostReciveRPort(PostReciveRPort object) {
		return null;
	}

	/**
	 * Returns the result of interpreting the object as an instance of '<em>Post Recive PPort</em>'.
	 * <!-- begin-user-doc -->
	 * This implementation returns null;
	 * returning a non-null result will terminate the switch.
	 * <!-- end-user-doc -->
	 * @param object the target of the switch.
	 * @return the result of interpreting the object as an instance of '<em>Post Recive PPort</em>'.
	 * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
	 * @generated
	 */
	public T casePostRecivePPort(PostRecivePPort object) {
		return null;
	}

	/**
	 * Returns the result of interpreting the object as an instance of '<em>Variable</em>'.
	 * <!-- begin-user-doc -->
	 * This implementation returns null;
	 * returning a non-null result will terminate the switch.
	 * <!-- end-user-doc -->
	 * @param object the target of the switch.
	 * @return the result of interpreting the object as an instance of '<em>Variable</em>'.
	 * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
	 * @generated
	 */
	public T caseVariable(Variable object) {
		return null;
	}

	/**
	 * Returns the result of interpreting the object as an instance of '<em>Variable Set</em>'.
	 * <!-- begin-user-doc -->
	 * This implementation returns null;
	 * returning a non-null result will terminate the switch.
	 * <!-- end-user-doc -->
	 * @param object the target of the switch.
	 * @return the result of interpreting the object as an instance of '<em>Variable Set</em>'.
	 * @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
	 * @generated
	 */
	public T caseVariableSet(VariableSet object) {
		return null;
	}

	/**
	 * Returns the result of interpreting the object as an instance of '<em>EObject</em>'.
	 * <!-- begin-user-doc -->
	 * This implementation returns null;
	 * returning a non-null result will terminate the switch, but this is the last case anyway.
	 * <!-- end-user-doc -->
	 * @param object the target of the switch.
	 * @return the result of interpreting the object as an instance of '<em>EObject</em>'.
	 * @see #doSwitch(org.eclipse.emf.ecore.EObject)
	 * @generated
	 */
	@Override
	public T defaultCase(EObject object) {
		return null;
	}

} //AutoSARSwitch
